/*
    Copyright 2011 - Tommi Laukkanen (www.substanceofcode.com)

    This file is part of MeeToDo.

    MeeToDo is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    MeeToDo is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public License
    along with MeeToDo. If not, see <http://www.gnu.org/licenses/>.
*/

import QtQuick 1.1

Item {
    id: icon
    width: 48
    height: 48
    property string pic: ""
    property string label: ""
    signal clicked()

    Image {
        source: icon.pic // "../pics/doc_delete.png"
        opacity: mouse.pressed ? 0.5 : 1
        /*Text {
            text: icon.label
            color: "#eee"
            font.pixelSize: 10
            anchors.horizontalCenter: parent.horizontalCenter
            anchors.top: parent.bottom
        }*/
        MouseArea {
            id: mouse
            anchors.centerIn: parent
            width: 60
            height: 60
            onClicked: icon.clicked()
        }
    }
}
